package com.study.concurrentprogramming.threadPool;

import java.util.concurrent.Callable;
import java.util.concurrent.TimeUnit;

/**
 * @Description : callable task
 * @Version : V1.0.0
 * @Date : 2022/1/12 9:17
 */
public class MyCallable implements Callable<String> {
    @Override
    public String call() throws Exception {
        String name = Thread.currentThread().getName();
        System.out.println(name + " exe");
        TimeUnit.SECONDS.sleep(3);
        return Thread.currentThread().getName();
    }
}
